﻿Imports DAO
Imports DTO

Public Class HoaDonBUS
    Public Shared Function ThemHoaDon(ByVal hd As HoaDonDTO) As Boolean
        HoaDonDAO.Insert(hd)
        Return True
    End Function
    Public Shared Function ThemHoaDonChiTiet(ByVal hd As HoaDonDTO) As Boolean
        If HoaDonDAO.SelectSachLikeMaSach(hd.MaHoaDon, hd.MaSach) Is Nothing Then
            HoaDonDAO.InsertChitiet(hd)
            Return True
        Else
            Return False
        End If
    End Function
End Class
